home *** CD-ROM | disk | FTP | other *** search
/ Supercompiler 1997 / SUPERCOMPILER97.iso / Delphi 3.0 / DATA.Z / vcspell3.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1997-01-30  |  41.4 KB  |  954 lines

  1. unit vcspell3;
  2.  
  3. { VCI VisualSpeller Library }
  4. { Version 2.0 }
  5.  
  6. interface
  7.  
  8. uses Windows, ActiveX, Classes, Graphics, OleCtrls, StdVCL;
  9.  
  10. const
  11.   LIBID_VspelocxLib: TGUID = '{97F4CED3-9103-11CE-8385-524153480001}';
  12.  
  13. const
  14.  
  15. { Dictionary category constants }
  16.  
  17. { DictionaryCategories }
  18.  
  19.   VSCAT_STANDARD = 256;
  20.   VSCAT_IRLIST = 256;
  21.   VSCAT_CUSTOM = 512;
  22.   VSCAT_ENABLED = 1024;
  23.   VSCAT_DISABLED = 2048;
  24.  
  25. { Dictionary status constants }
  26.  
  27. { DictionaryStatusBits }
  28.  
  29.   VSDSTAT_ENABLED = 1;
  30.   VSDSTAT_LOADED = 2;
  31.   VSDSTAT_IRLIST_ENABLED = 4;
  32.   VSDSTAT_UPDATEABLE = 8;
  33.   VSDSTAT_READONLY = 16;
  34.   VSDSTAT_EXTENDED = 32;
  35.   VSDSTAT_HYPHENATION = 64;
  36.   VSDSTAT_PHONETICS = 128;
  37.   VSDSTAT_COMMONLIST = 256;
  38.  
  39. { Dictionary language code constants }
  40.  
  41. { DictionaryLanguageCodes }
  42.  
  43.   VSLANG_AMERICAN = 0;
  44.   VSLANG_ENGLISH = 1;
  45.   VSLANG_FRENCH = 2;
  46.   VSLANG_GERMAN = 3;
  47.   VSLANG_SPANISH = 4;
  48.   VSLANG_PORTUGUESE = 5;
  49.   VSLANG_ITALIAN = 6;
  50.   VSLANG_DUTCH = 7;
  51.   VSLANG_SWEDISH = 8;
  52.   VSLANG_FINNISH = 9;
  53.   VSLANG_NORWEGIAN = 10;
  54.   VSLANG_LATIN = 11;
  55.   VSLANG_WELSH = 12;
  56.   VSLANG_POLISH = 13;
  57.   VSLANG_HUNGARIAN = 14;
  58.   VSLANG_FLEMISH = 15;
  59.   VSLANG_CZECH = 16;
  60.   VSLANG_ICELANDIC = 17;
  61.   VSLANG_ESPERANTO = 18;
  62.   VSLANG_CATALAN = 19;
  63.   VSLANG_ROMANIAN = 20;
  64.   VSLANG_BULGARIAN = 21;
  65.   VSLANG_RUSSIAN = 22;
  66.   VSLANG_QUECHUA = 23;
  67.   VSLANG_TURKISH = 24;
  68.   VSLANG_INDONESIAN = 25;
  69.   VSLANG_HEBREW = 26;
  70.   VSLANG_DANISH = 27;
  71.   VSLANG_CANADIAN = 28;
  72.  
  73. { Event option constants }
  74.  
  75. { EventOptionBits }
  76.  
  77.   VSEVOPT_COMPLETE = 1;
  78.   VSEVOPT_FOUND = 2;
  79.   VSEVOPT_MISSPELLED = 4;
  80.   VSEVOPT_BEFORE_REPLACE = 8;
  81.   VSEVOPT_AFTER_POPUP = 16;
  82.   VSEVOPT_CHECK_STATUS = 32;
  83.   VSEVOPT_CHECK_ERROR = 64;
  84.   VSEVOPT_AFTER_REPLACE = 128;
  85.   VSEVOPT_CLICK_IN = 256;
  86.   VSEVOPT_CLICK_OUT = 512;
  87.   VSEVOPT_DEFAULTS = 65533;
  88.  
  89. { Search order constants }
  90.  
  91. { SearchOrderCodes }
  92.  
  93.   VSORDER_SCIR = 0;
  94.   VSORDER_CIRS = 2;
  95.   VSORDER_IRSC = 3;
  96.   VSORDER_SIRC = 4;
  97.   VSORDER_CSIR = 6;
  98.   VSORDER_IRCS = 7;
  99.   VSORDER_NO_LOOKAHEAD = 8;
  100.  
  101. { Spell option constants }
  102.  
  103. { SpellOptionBits }
  104.  
  105.   VSOPT_AUTO_REPLACE = 1;
  106.   VSOPT_AUTO_SUGGEST = 2;
  107.   VSOPT_AUTO_POPUP = 4;
  108.   VSOPT_IGNORE_FULL_CAPS = 8;
  109.   VSOPT_IGNORE_PARTIAL_NUMBERS = 16;
  110.   VSOPT_MULTILINE = 32;
  111.   VSOPT_IGNORE_PURE_NUMBERS = 64;
  112.   VSOPT_ALLOW_JOINED_WORDS = 128;
  113.   VSOPT_EXACT_MATCH = 256;
  114.   VSOPT_RETURN_EACH_WORD = 512;
  115.   VSOPT_REPLACE_RECHECK = 1024;
  116.   VSOPT_DEFAULTS = 1127;
  117.  
  118. { Suggestion option constants }
  119.  
  120. { SuggestOptionBits }
  121.  
  122.   VSSUGOPT_CAPITALIZATION = 1;
  123.   VSSUGOPT_CHARSWAP = 2;
  124.   VSSUGOPT_DELETES = 4;
  125.   VSSUGOPT_DOUBLES = 8;
  126.   VSSUGOPT_HYPHENS = 16;
  127.   VSSUGOPT_SPLITS = 32;
  128.   VSSUGOPT_EXCHANGES = 64;
  129.   VSSUGOPT_INSERTIONS = 512;
  130.   VSSUGOPT_DEFAULTS = 639;
  131.  
  132. { Ignore/replace constants }
  133.  
  134. { IgnoreReplaceCodes }
  135.  
  136.   VSIR_GLOBAL = 1;
  137.   VSIR_PROMPT = 2;
  138.   VSIR_IGNORE = 4;
  139.   VSIR_REPLACE = 8;
  140.   VSIR_HYPHENATION = 16;
  141.   VSIR_SPELLED_OK = 5;
  142.   VSIR_REPLACE_ALL = 9;
  143.   VSIR_MISSPELLED = 6;
  144.   VSIR_PROMPT_REPLACE = 10;
  145.  
  146. { Event action constants }
  147.  
  148. { EventActionCodes }
  149.  
  150.   VS_DEFAULT_HANDLING = 0;
  151.   VS_EVENT_HANDLED = 1;
  152.   VS_CANCEL_SPELLCHECK = 2;
  153.  
  154. { Button click constants }
  155.  
  156. { ButtonClickBits }
  157.  
  158.   VSCLICK_WORD_MISSPELLED_HELP = 1;
  159.   VSCLICK_OPTIONS = 2;
  160.   VSCLICK_PROMPT_REPLACE = 4;
  161.   VSCLICK_ADD_TO_CUSTOM = 8;
  162.   VSCLICK_REPLACE_ALL = 16;
  163.   VSCLICK_REPLACE = 32;
  164.   VSCLICK_IGNORE_ALL = 64;
  165.   VSCLICK_IGNORE = 128;
  166.   VSCLICK_SUGGEST_NOT_FOUND = 256;
  167.   VSCLICK_SUGGEST_REPLACE_WITH = 512;
  168.   VSCLICK_CANCEL_SPELLCHECK = 1024;
  169.   VSCLICK_THESAURUS = 2048;
  170.   VSCLICK_OPTIONS_HELP = 65536;
  171.   VSCLICK_OPTIONS_OK = 131072;
  172.   VSCLICK_OPTIONS_CANCEL = 262144;
  173.   VSCLICK_OPEN_CUSTOM = 524288;
  174.   VSCLICK_CLOSE_CUSTOM = 1048576;
  175.   VSCLICK_OPEN_STANDARD = 2097152;
  176.   VSCLICK_CLOSE_STANDARD = 4194304;
  177.   VSCLICK_THESAURUS_OK = 16777216;
  178.   VSCLICK_THESAURUS_SEARCH = 33554432;
  179.   VSCLICK_THESAURUS_CANCEL = 67108864;
  180.   VSCLICK_THESAURUS_HELP = 134217728;
  181.  
  182. { Dialog element constants }
  183.  
  184. { DialogElementBits }
  185.  
  186.   VSD_WORD_MISSPELLED_HELP = 1;
  187.   VSD_OPTIONS = 2;
  188.   VSD_PROMPT_REPLACE = 4;
  189.   VSD_ADD_TO_CUSTOM = 8;
  190.   VSD_REPLACE_ALL = 16;
  191.   VSD_REPLACE = 32;
  192.   VSD_IGNORE_ALL = 64;
  193.   VSD_IGNORE = 128;
  194.   VSD_SUGGEST_NOT_FOUND = 256;
  195.   VSD_SUGGEST_REPLACE_WITH = 512;
  196.   VSD_CANCEL_SPELLCHECK = 1024;
  197.   VSD_SUGGESTIONS_LIST = 2048;
  198.   VSD_REPLACE_BOX = 4096;
  199.   VSD_CUSTOM_LIST = 8192;
  200.   VSD_THESAURUS = 16384;
  201.   VSD_OPTIONS_HELP = 65536;
  202.   VSD_CUSTOMS = 131072;
  203.   VSD_STANDARDS = 262144;
  204.   VSD_PERFORMANCE = 524288;
  205.   VSD_SUGGESTION_LIMIT = 1048576;
  206.   VSD_AUTO_SUGGESTIONS = 2097152;
  207.   VSD_EXACT_MATCH = 4194304;
  208.   VSD_IGNORE_FULL_CAPS = 8388608;
  209.   VSD_IGNORE_PARTIAL = 16777216;
  210.   VSD_IGNORE_PURE = 33554432;
  211.   VSD_ALLOW_JOINED = 67108864;
  212.   VSD_RECHECK = 134217728;
  213.   VSD_THESAURUS_HELP = 268435456;
  214.   VSD_THESAURUS_SEARCH = 536870912;
  215.  
  216. { ResultCode status constants }
  217.  
  218. { ResultStatusCodes }
  219.  
  220.   VSR_WORD_MISSPELLED = -1;
  221.   VSR_IGNORE_REPLACE = -2;
  222.   VSR_CHECK_CANCELED = -3;
  223.   VSR_BREAK = -4;
  224.   VSR_FOUND = -5;
  225.   VSR_REPLACED = -6;
  226.   VSR_CHANGED = -7;
  227.   VSR_END_LIST = -8;
  228.   VSR_ENTRY_NOT_FOUND = -9;
  229.   VSR_OPENED_READONLY = -11;
  230.   VSR_REPLACE_OVERFLOW = -12;
  231.   VSR_NOT_ADDED = -13;
  232.   VSR_POPPED = -14;
  233.   VSR_CLICK_IN = -15;
  234.   VSR_CLICK_OUT = -16;
  235.  
  236. { ResultCode error constants }
  237.  
  238. { ResultErrorCodes }
  239.  
  240.   VSR_NO_ERROR = 0;
  241.   VSR_WORD_TOO_LONG = 1;
  242.   VSR_NO_MISSPELL = 2;
  243.   VSR_ALREADY_OPEN = 4;
  244.   VSR_OPEN_FAILED = 5;
  245.   VSR_CREATE_FAILED = 6;
  246.   VSR_INVALID_DICTIONARY = 7;
  247.   VSR_WRITE_FAILURE = 9;
  248.   VSR_READ_FAILURE = 10;
  249.   VSR_BAD_FILE_NAME = 11;
  250.   VSR_NOT_UPDATEABLE = 12;
  251.   VSR_DUPLICATE_WORD = 13;
  252.   VSR_BAD_CUSTOM = 14;
  253.   VSR_IN_EVENT = 15;
  254.   VSR_NOT_LOADED = 16;
  255.   VSR_REPLACE_ERROR = 17;
  256.   VSR_CACHE_ERROR = 18;
  257.   VSR_INVALID_CONTEXT = 19;
  258.   VSR_NOTHING_TO_CHECK = 20;
  259.   VSR_DIALOG_ERROR = 21;
  260.   VSR_OUT_OF_MEMORY = 22;
  261.   VSR_BAD_INDEX = 23;
  262.   VSR_OUT_OF_STRING_SPACE = 24;
  263.   VSR_IN_DIALOG = 25;
  264.   VSR_FILE_EXISTS = 26;
  265.  
  266. { Runtime error constants }
  267.  
  268. { RuntimeErrorCodes }
  269.  
  270.   VB_OFFSET = 32350;
  271.   VBR_WORD_TOO_LONG = 32351;
  272.   VBR_NO_MISSPELL = 32352;
  273.   VBR_ALREADY_OPEN = 32354;
  274.   VBR_OPEN_FAILED = 32355;
  275.   VBR_CREATE_FAILED = 32356;
  276.   VBR_INVALID_DICTIONARY = 32357;
  277.   VBR_WRITE_FAILURE = 32359;
  278.   VBR_READ_FAILURE = 32360;
  279.   VBR_BAD_FILE_NAME = 32361;
  280.   VBR_NOT_UPDATEABLE = 32362;
  281.   VBR_DUPLICATE_WORD = 32363;
  282.   VBR_BAD_CUSTOM = 32364;
  283.   VBR_IN_EVENT = 32365;
  284.   VBR_NOT_LOADED = 32366;
  285.   VBR_REPLACE_ERROR = 32367;
  286.   VBR_CACHE_ERROR = 32368;
  287.   VBR_INVALID_CONTEXT = 32369;
  288.   VBR_NOTHING_TO_CHECK = 32370;
  289.   VBR_DIALOG_ERROR = 32371;
  290.   VBR_OUT_OF_MEMORY = 32372;
  291.   VBR_BAD_INDEX = 32373;
  292.   VBR_OUT_OF_STRING_SPACE = 32374;
  293.   VBR_IN_DIALOG = 32375;
  294.   VBR_FILE_EXISTS = 32376;
  295.  
  296. { Miscellaneous constants }
  297.  
  298. { MiscellaneousCodes }
  299.  
  300.   VS_ALL = 0;
  301.   VS_MAXWORDSIZE = 75;
  302.  
  303. const
  304.  
  305. { Component class GUIDs }
  306.   Class_VSSpell: TGUID = '{97F4CED0-9103-11CE-8385-524153480001}';
  307.  
  308. type
  309.  
  310. { Forward declarations }
  311.   _DVSpell = dispinterface;
  312.   _DVSpellEvents = dispinterface;
  313.  
  314.   DictionaryCategories = TOleEnum;
  315.   DictionaryStatusBits = TOleEnum;
  316.   DictionaryLanguageCodes = TOleEnum;
  317.   EventOptionBits = TOleEnum;
  318.   SearchOrderCodes = TOleEnum;
  319.   SpellOptionBits = TOleEnum;
  320.   SuggestOptionBits = TOleEnum;
  321.   IgnoreReplaceCodes = TOleEnum;
  322.   EventActionCodes = TOleEnum;
  323.   ButtonClickBits = TOleEnum;
  324.   DialogElementBits = TOleEnum;
  325.   ResultStatusCodes = TOleEnum;
  326.   ResultErrorCodes = TOleEnum;
  327.   RuntimeErrorCodes = TOleEnum;
  328.   MiscellaneousCodes = TOleEnum;
  329.  
  330. { Dispatch interface for VisualSpeller Control }
  331.  
  332.   _DVSpell = dispinterface
  333.     ['{97F4CED1-9103-11CE-8385-524153480001}']
  334.     property AutoPopup: WordBool dispid 4;
  335.     property AutoReplace: WordBool dispid 5;
  336.     property AutoSuggest: WordBool dispid 6;
  337.     property BreakWordCount: Smallint dispid 7;
  338.     property CacheSize: Smallint dispid 8;
  339.     property ErrorOffset: Smallint dispid 1;
  340.     property IgnoreFullCaps: WordBool dispid 9;
  341.     property IgnorePartialNumbers: WordBool dispid 10;
  342.     property MaxSuggestions: Smallint dispid 11;
  343.     property MultiLine: WordBool dispid 12;
  344.     property SuggestionsLimit: Smallint dispid 13;
  345.     property Version: WideString dispid 14;
  346.     property CurrentLine: Integer dispid 15;
  347.     property CustomCount: Smallint dispid 16;
  348.     property DLLHandle: Integer dispid 17;
  349.     property EventOptions: Smallint dispid 18;
  350.     property Hyphenation: WideString dispid 19;
  351.     property IRAction: Smallint dispid 20;
  352.     property IRWhereFound: Smallint dispid 21;
  353.     property LineBreak: WideString dispid 22;
  354.     property LineOffset: Smallint dispid 23;
  355.     property MisspelledWord: WideString dispid 24;
  356.     property ReplaceCount: Integer dispid 25;
  357.     property ReplacementWord: WideString dispid 26;
  358.     property ResultCode: Smallint dispid 27;
  359.     property ResumeOffset: Integer dispid 28;
  360.     property SearchOrder: Smallint dispid 29;
  361.     property SpellOptions: Smallint dispid 30;
  362.     property StandardCount: Smallint dispid 31;
  363.     property SuggestOptions: Smallint dispid 32;
  364.     property SuggestionCount: Smallint dispid 33;
  365.     property Text: WideString dispid 34;
  366.     property WhereFound: Smallint dispid 35;
  367.     property WordCount: Integer dispid 36;
  368.     property WordOffset: Integer dispid 37;
  369.     property AllowJoinedWords: WordBool dispid 38;
  370.     property DialogLeft: Integer dispid 39;
  371.     property DialogTop: Integer dispid 40;
  372.     property ReplaceRecheck: WordBool dispid 41;
  373.     property DialogBgColor: TColor dispid 42;
  374.     property DialogLeftActual: Integer dispid 43;
  375.     property DialogTopActual: Integer dispid 44;
  376.     property ReplaceOccurred: WordBool dispid 45;
  377.     property SuggestionsMade: WordBool dispid 46;
  378.     property WordLength: Smallint dispid 47;
  379.     property CacheHits: Integer dispid 48;
  380.     property CacheMisses: Integer dispid 49;
  381.     property TimerTicks: Integer dispid 50;
  382.     property UserData: Integer dispid 51;
  383.     property CheckedWord: WideString dispid 52;
  384.     property CommonIRListIsEnabled: WordBool dispid 53;
  385.     property WordMisspelledTitle: WideString dispid 54;
  386.     property OptionsTitle: WideString dispid 55;
  387.     property ErrorTitle: WideString dispid 56;
  388.     property WordMisspelledHelpFile: WideString dispid 57;
  389.     property OptionsHelpFile: WideString dispid 58;
  390.     property DialogElements: Integer dispid 59;
  391.     property DialogWidth: Integer dispid 60;
  392.     property DialogHeight: Integer dispid 61;
  393.     property ErrorText: WideString dispid 62;
  394.     property ClickedButton: Integer dispid 63;
  395.     property ClickInfo: Integer dispid 64;
  396.     property ClickInfoText: WideString dispid 65;
  397.     property AddToCommonIRList: Smallint dispid 66;
  398.     property BeginCheck: Smallint dispid 67;
  399.     property CheckText: WideString dispid 68;
  400.     property CheckWord: WideString dispid 69;
  401.     property ClearCounts: Smallint dispid 70;
  402.     property ClearOffsets: Smallint dispid 71;
  403.     property FindSuggestions: WideString dispid 72;
  404.     property ReplaceLastWord: Smallint dispid 73;
  405.     property ResumeCheck: Smallint dispid 74;
  406.     property ClearSuggestions: Smallint dispid 75;
  407.     property PopupError: Smallint dispid 76;
  408.     property PopupOptions: Smallint dispid 77;
  409.     property PopupWordMisspelled: Smallint dispid 78;
  410.     property CreateCustom: WideString dispid 79;
  411.     property ResumeWithRecheck: Smallint dispid 80;
  412.     property EnableCommonIRList: WordBool dispid 81;
  413.     property ClearCommonIRList: Smallint dispid 82;
  414.     property RemoveFromCommonIRList: WideString dispid 83;
  415.     property EnableEventOptions: Smallint dispid 84;
  416.     property DisableEventOptions: Smallint dispid 85;
  417.     property EnableSpellOptions: Smallint dispid 86;
  418.     property DisableSpellOptions: Smallint dispid 87;
  419.     property EnableSuggestOptions: Smallint dispid 88;
  420.     property DisableSuggestOptions: Smallint dispid 89;
  421.     property EnableDialogElements: Integer dispid 90;
  422.     property DisableDialogElements: Integer dispid 91;
  423.     property _Text: WideString dispid 0;
  424.     property StandardDictionary: WideString dispid 2;
  425.     property CustomDictionary: WideString dispid 3;
  426.     property OpenStandard[loadit: WordBool]: WideString writeonly dispid 92;
  427.     property DictionaryLanguage[index: Smallint]: Smallint readonly dispid 107;
  428.     property DictionaryName[index: Smallint]: WideString readonly dispid 108;
  429.     property DictionaryStatus[index: Smallint]: Smallint readonly dispid 109;
  430.     property DictionaryIsEnabled[index: Smallint]: WordBool readonly dispid 110;
  431.     property DictionaryNameFull[index: Smallint]: WideString readonly dispid 111;
  432.     property StandardIRListIsEnabled[index: Smallint]: WordBool readonly dispid 112;
  433.     property DictionaryIsLoaded[index: Smallint]: WordBool readonly dispid 113;
  434.     property DictionaryPerformance[index: Smallint]: Smallint dispid 114;
  435.     property Suggestion[index: Smallint]: WideString readonly dispid 115;
  436.     property CustomIsUpdateable[index: Smallint]: WordBool readonly dispid 116;
  437.     property AddToStandardIRList[index: Smallint]: Smallint writeonly dispid 93;
  438.     property AddSuggestion[matchcode: Smallint]: WideString writeonly dispid 94;
  439.     property AddToCustom[index: Smallint]: Smallint writeonly dispid 95;
  440.     property ClearStandardIRList[index: Smallint]: Smallint writeonly dispid 96;
  441.     property CloseDictionary[index: Smallint]: Smallint writeonly dispid 97;
  442.     property GetEntry[index: Smallint]: Integer writeonly dispid 98;
  443.     property RemoveFromStandardIRList[index: Smallint]: WideString writeonly dispid 99;
  444.     property DictionaryPerformanceActual[index: Smallint]: Smallint readonly dispid 117;
  445.     property DictionaryBlockCount[index: Smallint]: Smallint readonly dispid 118;
  446.     property DictionaryBlockSize[index: Smallint]: Smallint readonly dispid 119;
  447.     property DictionaryCommonCount[index: Smallint]: Smallint readonly dispid 120;
  448.     property DictionaryCompatibilityBits[index: Smallint]: Smallint readonly dispid 121;
  449.     property DictionaryCopyright[index: Smallint]: WideString readonly dispid 122;
  450.     property DictionaryCopyrightDerived[index: Smallint]: WideString readonly dispid 123;
  451.     property DictionaryFlags[index: Smallint]: Smallint readonly dispid 124;
  452.     property DictionaryLoadCount[index: Smallint]: Smallint readonly dispid 125;
  453.     property DictionaryMakerVersion[index: Smallint]: Smallint readonly dispid 126;
  454.     property DictionaryOpenCount[index: Smallint]: Smallint readonly dispid 127;
  455.     property DictionarySymbolSetSize[index: Smallint]: Smallint readonly dispid 128;
  456.     property DictionaryWordCount[index: Smallint]: Integer readonly dispid 129;
  457.     property CreateCustomExtended[index: Smallint]: WideString writeonly dispid 100;
  458.     property EnableDictionary[index: Smallint]: WordBool writeonly dispid 101;
  459.     property EnableCustomUpdate[index: Smallint]: WordBool writeonly dispid 102;
  460.     property LoadDictionary[index: Smallint]: Smallint writeonly dispid 103;
  461.     property UnloadDictionary[index: Smallint]: Smallint writeonly dispid 104;
  462.     property CustomIsReadOnly[index: Smallint]: WordBool readonly dispid 130;
  463.     property CustomIsExtended[index: Smallint]: WordBool readonly dispid 131;
  464.     property EnableStandardIRList[index: Smallint]: WordBool writeonly dispid 105;
  465.     property OpenCustom[loadit: WordBool]: WideString writeonly dispid 106;
  466.     procedure AboutBox; dispid -552;
  467.   end;
  468.  
  469. { Event interface for VisualSpeller Control }
  470.  
  471.   _DVSpellEvents = dispinterface
  472.     ['{97F4CED2-9103-11CE-8385-524153480001}']
  473.     procedure Misspelled(var  {IDL_None} EventAction: Smallint); dispid 1;
  474.     procedure Complete(var  {IDL_None} EventAction: Smallint); dispid 2;
  475.     procedure Found(var  {IDL_None} EventAction: Smallint); dispid 3;
  476.     procedure BeforeReplace(var  {IDL_None} EventAction: Smallint); dispid 4;
  477.     procedure AfterReplace(var  {IDL_None} EventAction: Smallint); dispid 5;
  478.     procedure AfterPopup(var  {IDL_None} EventAction: Smallint); dispid 6;
  479.     procedure CheckStatus(var  {IDL_None} EventAction: Smallint); dispid 7;
  480.     procedure CheckError(var  {IDL_None} EventAction: Smallint); dispid 8;
  481.     procedure ClickIn(var  {IDL_None} EventAction: Smallint); dispid 9;
  482.     procedure ClickOut(var  {IDL_None} EventAction: Smallint); dispid 10;
  483.   end;
  484.  
  485. { VCI VisualSpeller Spellchecker }
  486.  
  487.   TVSSpellMisspelled = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  488.   TVSSpellComplete = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  489.   TVSSpellFound = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  490.   TVSSpellBeforeReplace = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  491.   TVSSpellAfterReplace = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  492.   TVSSpellAfterPopup = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  493.   TVSSpellCheckStatus = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  494.   TVSSpellCheckError = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  495.   TVSSpellClickIn = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  496.   TVSSpellClickOut = procedure(Sender: TObject; var  {IDL_None} EventAction: Smallint) of object;
  497.  
  498.   TVSSpell = class(TOleControl)
  499.   private
  500.     FOnMisspelled: TVSSpellMisspelled;
  501.     FOnComplete: TVSSpellComplete;
  502.     FOnFound: TVSSpellFound;
  503.     FOnBeforeReplace: TVSSpellBeforeReplace;
  504.     FOnAfterReplace: TVSSpellAfterReplace;
  505.     FOnAfterPopup: TVSSpellAfterPopup;
  506.     FOnCheckStatus: TVSSpellCheckStatus;
  507.     FOnCheckError: TVSSpellCheckError;
  508.     FOnClickIn: TVSSpellClickIn;
  509.     FOnClickOut: TVSSpellClickOut;
  510.     FIntf: _DVSpell;
  511.     procedure Set_OpenStandard(loadit: WordBool; const Value: WideString);
  512.     function Get_DictionaryLanguage(index: Smallint): Smallint;
  513.     function Get_DictionaryName(index: Smallint): WideString;
  514.     function Get_DictionaryStatus(index: Smallint): Smallint;
  515.     function Get_DictionaryIsEnabled(index: Smallint): WordBool;
  516.     function Get_DictionaryNameFull(index: Smallint): WideString;
  517.     function Get_StandardIRListIsEnabled(index: Smallint): WordBool;
  518.     function Get_DictionaryIsLoaded(index: Smallint): WordBool;
  519.     function Get_DictionaryPerformance(index: Smallint): Smallint;
  520.     procedure Set_DictionaryPerformance(index: Smallint; Value: Smallint);
  521.     function Get_Suggestion(index: Smallint): WideString;
  522.     function Get_CustomIsUpdateable(index: Smallint): WordBool;
  523.     procedure Set_AddToStandardIRList(index: Smallint; Value: Smallint);
  524.     procedure Set_AddSuggestion(matchcode: Smallint; const Value: WideString);
  525.     procedure Set_AddToCustom(index: Smallint; Value: Smallint);
  526.     procedure Set_ClearStandardIRList(index: Smallint; Value: Smallint);
  527.     procedure Set_CloseDictionary(index: Smallint; Value: Smallint);
  528.     procedure Set_GetEntry(index: Smallint; Value: Integer);
  529.     procedure Set_RemoveFromStandardIRList(index: Smallint; const Value: WideString);
  530.     function Get_DictionaryPerformanceActual(index: Smallint): Smallint;
  531.     function Get_DictionaryBlockCount(index: Smallint): Smallint;
  532.     function Get_DictionaryBlockSize(index: Smallint): Smallint;
  533.     function Get_DictionaryCommonCount(index: Smallint): Smallint;
  534.     function Get_DictionaryCompatibilityBits(index: Smallint): Smallint;
  535.     function Get_DictionaryCopyright(index: Smallint): WideString;
  536.     function Get_DictionaryCopyrightDerived(index: Smallint): WideString;
  537.     function Get_DictionaryFlags(index: Smallint): Smallint;
  538.     function Get_DictionaryLoadCount(index: Smallint): Smallint;
  539.     function Get_DictionaryMakerVersion(index: Smallint): Smallint;
  540.     function Get_DictionaryOpenCount(index: Smallint): Smallint;
  541.     function Get_DictionarySymbolSetSize(index: Smallint): Smallint;
  542.     function Get_DictionaryWordCount(index: Smallint): Integer;
  543.     procedure Set_CreateCustomExtended(index: Smallint; const Value: WideString);
  544.     procedure Set_EnableDictionary(index: Smallint; Value: WordBool);
  545.     procedure Set_EnableCustomUpdate(index: Smallint; Value: WordBool);
  546.     procedure Set_LoadDictionary(index: Smallint; Value: Smallint);
  547.     procedure Set_UnloadDictionary(index: Smallint; Value: Smallint);
  548.     function Get_CustomIsReadOnly(index: Smallint): WordBool;
  549.     function Get_CustomIsExtended(index: Smallint): WordBool;
  550.     procedure Set_EnableStandardIRList(index: Smallint; Value: WordBool);
  551.     procedure Set_OpenCustom(loadit: WordBool; const Value: WideString);
  552.   protected
  553.     procedure InitControlData; override;
  554.     procedure InitControlInterface(const Obj: IUnknown); override;
  555.   public
  556.     procedure AboutBox;
  557.     property ControlInterface: _DVSpell read FIntf;
  558.     property OpenStandard[loadit: WordBool]: WideString write Set_OpenStandard;
  559.     property DictionaryLanguage[index: Smallint]: Smallint read Get_DictionaryLanguage;
  560.     property DictionaryName[index: Smallint]: WideString read Get_DictionaryName;
  561.     property DictionaryStatus[index: Smallint]: Smallint read Get_DictionaryStatus;
  562.     property DictionaryIsEnabled[index: Smallint]: WordBool read Get_DictionaryIsEnabled;
  563.     property DictionaryNameFull[index: Smallint]: WideString read Get_DictionaryNameFull;
  564.     property StandardIRListIsEnabled[index: Smallint]: WordBool read Get_StandardIRListIsEnabled;
  565.     property DictionaryIsLoaded[index: Smallint]: WordBool read Get_DictionaryIsLoaded;
  566.     property DictionaryPerformance[index: Smallint]: Smallint read Get_DictionaryPerformance write Set_DictionaryPerformance;
  567.     property Suggestion[index: Smallint]: WideString read Get_Suggestion;
  568.     property CustomIsUpdateable[index: Smallint]: WordBool read Get_CustomIsUpdateable;
  569.     property AddToStandardIRList[index: Smallint]: Smallint write Set_AddToStandardIRList;
  570.     property AddSuggestion[matchcode: Smallint]: WideString write Set_AddSuggestion;
  571.     property AddToCustom[index: Smallint]: Smallint write Set_AddToCustom;
  572.     property ClearStandardIRList[index: Smallint]: Smallint write Set_ClearStandardIRList;
  573.     property CloseDictionary[index: Smallint]: Smallint write Set_CloseDictionary;
  574.     property GetEntry[index: Smallint]: Integer write Set_GetEntry;
  575.     property RemoveFromStandardIRList[index: Smallint]: WideString write Set_RemoveFromStandardIRList;
  576.     property DictionaryPerformanceActual[index: Smallint]: Smallint read Get_DictionaryPerformanceActual;
  577.     property DictionaryBlockCount[index: Smallint]: Smallint read Get_DictionaryBlockCount;
  578.     property DictionaryBlockSize[index: Smallint]: Smallint read Get_DictionaryBlockSize;
  579.     property DictionaryCommonCount[index: Smallint]: Smallint read Get_DictionaryCommonCount;
  580.     property DictionaryCompatibilityBits[index: Smallint]: Smallint read Get_DictionaryCompatibilityBits;
  581.     property DictionaryCopyright[index: Smallint]: WideString read Get_DictionaryCopyright;
  582.     property DictionaryCopyrightDerived[index: Smallint]: WideString read Get_DictionaryCopyrightDerived;
  583.     property DictionaryFlags[index: Smallint]: Smallint read Get_DictionaryFlags;
  584.     property DictionaryLoadCount[index: Smallint]: Smallint read Get_DictionaryLoadCount;
  585.     property DictionaryMakerVersion[index: Smallint]: Smallint read Get_DictionaryMakerVersion;
  586.     property DictionaryOpenCount[index: Smallint]: Smallint read Get_DictionaryOpenCount;
  587.     property DictionarySymbolSetSize[index: Smallint]: Smallint read Get_DictionarySymbolSetSize;
  588.     property DictionaryWordCount[index: Smallint]: Integer read Get_DictionaryWordCount;
  589.     property CreateCustomExtended[index: Smallint]: WideString write Set_CreateCustomExtended;
  590.     property EnableDictionary[index: Smallint]: WordBool write Set_EnableDictionary;
  591.     property EnableCustomUpdate[index: Smallint]: WordBool write Set_EnableCustomUpdate;
  592.     property LoadDictionary[index: Smallint]: Smallint write Set_LoadDictionary;
  593.     property UnloadDictionary[index: Smallint]: Smallint write Set_UnloadDictionary;
  594.     property CustomIsReadOnly[index: Smallint]: WordBool read Get_CustomIsReadOnly;
  595.     property CustomIsExtended[index: Smallint]: WordBool read Get_CustomIsExtended;
  596.     property EnableStandardIRList[index: Smallint]: WordBool write Set_EnableStandardIRList;
  597.     property OpenCustom[loadit: WordBool]: WideString write Set_OpenCustom;
  598.   published
  599.     property AutoPopup: WordBool index 4 read GetWordBoolProp write SetWordBoolProp stored False;
  600.     property AutoReplace: WordBool index 5 read GetWordBoolProp write SetWordBoolProp stored False;
  601.     property AutoSuggest: WordBool index 6 read GetWordBoolProp write SetWordBoolProp stored False;
  602.     property BreakWordCount: Smallint index 7 read GetSmallintProp write SetSmallintProp stored False;
  603.     property CacheSize: Smallint index 8 read GetSmallintProp write SetSmallintProp stored False;
  604.     property ErrorOffset: Smallint index 1 read GetSmallintProp write SetSmallintProp stored False;
  605.     property IgnoreFullCaps: WordBool index 9 read GetWordBoolProp write SetWordBoolProp stored False;
  606.     property IgnorePartialNumbers: WordBool index 10 read GetWordBoolProp write SetWordBoolProp stored False;
  607.     property MaxSuggestions: Smallint index 11 read GetSmallintProp write SetSmallintProp stored False;
  608.     property MultiLine: WordBool index 12 read GetWordBoolProp write SetWordBoolProp stored False;
  609.     property SuggestionsLimit: Smallint index 13 read GetSmallintProp write SetSmallintProp stored False;
  610.     property Version: WideString index 14 read GetWideStringProp write SetWideStringProp stored False;
  611.     property CurrentLine: Integer index 15 read GetIntegerProp write SetIntegerProp stored False;
  612.     property CustomCount: Smallint index 16 read GetSmallintProp write SetSmallintProp stored False;
  613.     property DLLHandle: Integer index 17 read GetIntegerProp write SetIntegerProp stored False;
  614.     property EventOptions: Smallint index 18 read GetSmallintProp write SetSmallintProp stored False;
  615.     property Hyphenation: WideString index 19 read GetWideStringProp write SetWideStringProp stored False;
  616.     property IRAction: Smallint index 20 read GetSmallintProp write SetSmallintProp stored False;
  617.     property IRWhereFound: Smallint index 21 read GetSmallintProp write SetSmallintProp stored False;
  618.     property LineBreak: WideString index 22 read GetWideStringProp write SetWideStringProp stored False;
  619.     property LineOffset: Smallint index 23 read GetSmallintProp write SetSmallintProp stored False;
  620.     property MisspelledWord: WideString index 24 read GetWideStringProp write SetWideStringProp stored False;
  621.     property ReplaceCount: Integer index 25 read GetIntegerProp write SetIntegerProp stored False;
  622.     property ReplacementWord: WideString index 26 read GetWideStringProp write SetWideStringProp stored False;
  623.     property ResultCode: Smallint index 27 read GetSmallintProp write SetSmallintProp stored False;
  624.     property ResumeOffset: Integer index 28 read GetIntegerProp write SetIntegerProp stored False;
  625.     property SearchOrder: Smallint index 29 read GetSmallintProp write SetSmallintProp stored False;
  626.     property SpellOptions: Smallint index 30 read GetSmallintProp write SetSmallintProp stored False;
  627.     property StandardCount: Smallint index 31 read GetSmallintProp write SetSmallintProp stored False;
  628.     property SuggestOptions: Smallint index 32 read GetSmallintProp write SetSmallintProp stored False;
  629.     property SuggestionCount: Smallint index 33 read GetSmallintProp write SetSmallintProp stored False;
  630.     property Text: WideString index 34 read GetWideStringProp write SetWideStringProp stored False;
  631.     property WhereFound: Smallint index 35 read GetSmallintProp write SetSmallintProp stored False;
  632.     property WordCount: Integer index 36 read GetIntegerProp write SetIntegerProp stored False;
  633.     property WordOffset: Integer index 37 read GetIntegerProp write SetIntegerProp stored False;
  634.     property AllowJoinedWords: WordBool index 38 read GetWordBoolProp write SetWordBoolProp stored False;
  635.     property DialogLeft: Integer index 39 read GetIntegerProp write SetIntegerProp stored False;
  636.     property DialogTop: Integer index 40 read GetIntegerProp write SetIntegerProp stored False;
  637.     property ReplaceRecheck: WordBool index 41 read GetWordBoolProp write SetWordBoolProp stored False;
  638.     property DialogBgColor: TColor index 42 read GetTColorProp write SetTColorProp stored False;
  639.     property DialogLeftActual: Integer index 43 read GetIntegerProp write SetIntegerProp stored False;
  640.     property DialogTopActual: Integer index 44 read GetIntegerProp write SetIntegerProp stored False;
  641.     property ReplaceOccurred: WordBool index 45 read GetWordBoolProp write SetWordBoolProp stored False;
  642.     property SuggestionsMade: WordBool index 46 read GetWordBoolProp write SetWordBoolProp stored False;
  643.     property WordLength: Smallint index 47 read GetSmallintProp write SetSmallintProp stored False;
  644.     property CacheHits: Integer index 48 read GetIntegerProp write SetIntegerProp stored False;
  645.     property CacheMisses: Integer index 49 read GetIntegerProp write SetIntegerProp stored False;
  646.     property TimerTicks: Integer index 50 read GetIntegerProp write SetIntegerProp stored False;
  647.     property UserData: Integer index 51 read GetIntegerProp write SetIntegerProp stored False;
  648.     property CheckedWord: WideString index 52 read GetWideStringProp write SetWideStringProp stored False;
  649.     property CommonIRListIsEnabled: WordBool index 53 read GetWordBoolProp write SetWordBoolProp stored False;
  650.     property WordMisspelledTitle: WideString index 54 read GetWideStringProp write SetWideStringProp stored False;
  651.     property OptionsTitle: WideString index 55 read GetWideStringProp write SetWideStringProp stored False;
  652.     property ErrorTitle: WideString index 56 read GetWideStringProp write SetWideStringProp stored False;
  653.     property WordMisspelledHelpFile: WideString index 57 read GetWideStringProp write SetWideStringProp stored False;
  654.     property OptionsHelpFile: WideString index 58 read GetWideStringProp write SetWideStringProp stored False;
  655.     property DialogElements: Integer index 59 read GetIntegerProp write SetIntegerProp stored False;
  656.     property DialogWidth: Integer index 60 read GetIntegerProp write SetIntegerProp stored False;
  657.     property DialogHeight: Integer index 61 read GetIntegerProp write SetIntegerProp stored False;
  658.     property ErrorText: WideString index 62 read GetWideStringProp write SetWideStringProp stored False;
  659.     property ClickedButton: Integer index 63 read GetIntegerProp write SetIntegerProp stored False;
  660.     property ClickInfo: Integer index 64 read GetIntegerProp write SetIntegerProp stored False;
  661.     property ClickInfoText: WideString index 65 read GetWideStringProp write SetWideStringProp stored False;
  662.     property AddToCommonIRList: Smallint index 66 read GetSmallintProp write SetSmallintProp stored False;
  663.     property BeginCheck: Smallint index 67 read GetSmallintProp write SetSmallintProp stored False;
  664.     property CheckText: WideString index 68 read GetWideStringProp write SetWideStringProp stored False;
  665.     property CheckWord: WideString index 69 read GetWideStringProp write SetWideStringProp stored False;
  666.     property ClearCounts: Smallint index 70 read GetSmallintProp write SetSmallintProp stored False;
  667.     property ClearOffsets: Smallint index 71 read GetSmallintProp write SetSmallintProp stored False;
  668.     property FindSuggestions: WideString index 72 read GetWideStringProp write SetWideStringProp stored False;
  669.     property ReplaceLastWord: Smallint index 73 read GetSmallintProp write SetSmallintProp stored False;
  670.     property ResumeCheck: Smallint index 74 read GetSmallintProp write SetSmallintProp stored False;
  671.     property ClearSuggestions: Smallint index 75 read GetSmallintProp write SetSmallintProp stored False;
  672.     property PopupError: Smallint index 76 read GetSmallintProp write SetSmallintProp stored False;
  673.     property PopupOptions: Smallint index 77 read GetSmallintProp write SetSmallintProp stored False;
  674.     property PopupWordMisspelled: Smallint index 78 read GetSmallintProp write SetSmallintProp stored False;
  675.     property CreateCustom: WideString index 79 read GetWideStringProp write SetWideStringProp stored False;
  676.     property ResumeWithRecheck: Smallint index 80 read GetSmallintProp write SetSmallintProp stored False;
  677.     property EnableCommonIRList: WordBool index 81 read GetWordBoolProp write SetWordBoolProp stored False;
  678.     property ClearCommonIRList: Smallint index 82 read GetSmallintProp write SetSmallintProp stored False;
  679.     property RemoveFromCommonIRList: WideString index 83 read GetWideStringProp write SetWideStringProp stored False;
  680.     property EnableEventOptions: Smallint index 84 read GetSmallintProp write SetSmallintProp stored False;
  681.     property DisableEventOptions: Smallint index 85 read GetSmallintProp write SetSmallintProp stored False;
  682.     property EnableSpellOptions: Smallint index 86 read GetSmallintProp write SetSmallintProp stored False;
  683.     property DisableSpellOptions: Smallint index 87 read GetSmallintProp write SetSmallintProp stored False;
  684.     property EnableSuggestOptions: Smallint index 88 read GetSmallintProp write SetSmallintProp stored False;
  685.     property DisableSuggestOptions: Smallint index 89 read GetSmallintProp write SetSmallintProp stored False;
  686.     property EnableDialogElements: Integer index 90 read GetIntegerProp write SetIntegerProp stored False;
  687.     property DisableDialogElements: Integer index 91 read GetIntegerProp write SetIntegerProp stored False;
  688.     property _Text: WideString index 0 read GetWideStringProp write SetWideStringProp stored False;
  689.     property StandardDictionary: WideString index 2 read GetWideStringProp write SetWideStringProp stored False;
  690.     property CustomDictionary: WideString index 3 read GetWideStringProp write SetWideStringProp stored False;
  691.     property OnMisspelled: TVSSpellMisspelled read FOnMisspelled write FOnMisspelled;
  692.     property OnComplete: TVSSpellComplete read FOnComplete write FOnComplete;
  693.     property OnFound: TVSSpellFound read FOnFound write FOnFound;
  694.     property OnBeforeReplace: TVSSpellBeforeReplace read FOnBeforeReplace write FOnBeforeReplace;
  695.     property OnAfterReplace: TVSSpellAfterReplace read FOnAfterReplace write FOnAfterReplace;
  696.     property OnAfterPopup: TVSSpellAfterPopup read FOnAfterPopup write FOnAfterPopup;
  697.     property OnCheckStatus: TVSSpellCheckStatus read FOnCheckStatus write FOnCheckStatus;
  698.     property OnCheckError: TVSSpellCheckError read FOnCheckError write FOnCheckError;
  699.     property OnClickIn: TVSSpellClickIn read FOnClickIn write FOnClickIn;
  700.     property OnClickOut: TVSSpellClickOut read FOnClickOut write FOnClickOut;
  701.   end;
  702.  
  703. procedure Register;
  704.  
  705. implementation
  706.  
  707. uses ComObj;
  708.  
  709. procedure TVSSpell.InitControlData;
  710. const
  711.   CEventDispIDs: array[0..9] of Integer = (
  712.     $00000001, $00000002, $00000003, $00000004, $00000005, $00000006,
  713.     $00000007, $00000008, $00000009, $0000000A);
  714.   CLicenseKey: array[0..19] of Word = (
  715.     $0043, $006F, $0070, $0079, $0072, $0069, $0067, $0068, $0074, $0020,
  716.     $0028, $0063, $0029, $0020, $0031, $0039, $0039, $0035, $0020, $0000);
  717.   CControlData: TControlData = (
  718.     ClassID: '{97F4CED0-9103-11CE-8385-524153480001}';
  719.     EventIID: '{97F4CED2-9103-11CE-8385-524153480001}';
  720.     EventCount: 10;
  721.     EventDispIDs: @CEventDispIDs;
  722.     LicenseKey: @CLicenseKey;
  723.     Flags: $00000000;
  724.     Version: 300;
  725.     FontCount: 0;
  726.     FontIDs: nil);
  727. begin
  728.   ControlData := @CControlData;
  729. end;
  730.  
  731. procedure TVSSpell.InitControlInterface(const Obj: IUnknown);
  732. begin
  733.   FIntf := Obj as _DVSpell;
  734. end;
  735.  
  736. procedure TVSSpell.AboutBox;
  737. begin
  738.   ControlInterface.AboutBox;
  739. end;
  740.  
  741. procedure TVSSpell.Set_OpenStandard(loadit: WordBool; const Value: WideString);
  742. begin
  743.   ControlInterface.OpenStandard[loadit] := Value;
  744. end;
  745.  
  746. function TVSSpell.Get_DictionaryLanguage(index: Smallint): Smallint;
  747. begin
  748.   Result := ControlInterface.DictionaryLanguage[index];
  749. end;
  750.  
  751. function TVSSpell.Get_DictionaryName(index: Smallint): WideString;
  752. begin
  753.   Result := ControlInterface.DictionaryName[index];
  754. end;
  755.  
  756. function TVSSpell.Get_DictionaryStatus(index: Smallint): Smallint;
  757. begin
  758.   Result := ControlInterface.DictionaryStatus[index];
  759. end;
  760.  
  761. function TVSSpell.Get_DictionaryIsEnabled(index: Smallint): WordBool;
  762. begin
  763.   Result := ControlInterface.DictionaryIsEnabled[index];
  764. end;
  765.  
  766. function TVSSpell.Get_DictionaryNameFull(index: Smallint): WideString;
  767. begin
  768.   Result := ControlInterface.DictionaryNameFull[index];
  769. end;
  770.  
  771. function TVSSpell.Get_StandardIRListIsEnabled(index: Smallint): WordBool;
  772. begin
  773.   Result := ControlInterface.StandardIRListIsEnabled[index];
  774. end;
  775.  
  776. function TVSSpell.Get_DictionaryIsLoaded(index: Smallint): WordBool;
  777. begin
  778.   Result := ControlInterface.DictionaryIsLoaded[index];
  779. end;
  780.  
  781. function TVSSpell.Get_DictionaryPerformance(index: Smallint): Smallint;
  782. begin
  783.   Result := ControlInterface.DictionaryPerformance[index];
  784. end;
  785.  
  786. procedure TVSSpell.Set_DictionaryPerformance(index: Smallint; Value: Smallint);
  787. begin
  788.   ControlInterface.DictionaryPerformance[index] := Value;
  789. end;
  790.  
  791. function TVSSpell.Get_Suggestion(index: Smallint): WideString;
  792. begin
  793.   Result := ControlInterface.Suggestion[index];
  794. end;
  795.  
  796. function TVSSpell.Get_CustomIsUpdateable(index: Smallint): WordBool;
  797. begin
  798.   Result := ControlInterface.CustomIsUpdateable[index];
  799. end;
  800.  
  801. procedure TVSSpell.Set_AddToStandardIRList(index: Smallint; Value: Smallint);
  802. begin
  803.   ControlInterface.AddToStandardIRList[index] := Value;
  804. end;
  805.  
  806. procedure TVSSpell.Set_AddSuggestion(matchcode: Smallint; const Value: WideString);
  807. begin
  808.   ControlInterface.AddSuggestion[matchcode] := Value;
  809. end;
  810.  
  811. procedure TVSSpell.Set_AddToCustom(index: Smallint; Value: Smallint);
  812. begin
  813.   ControlInterface.AddToCustom[index] := Value;
  814. end;
  815.  
  816. procedure TVSSpell.Set_ClearStandardIRList(index: Smallint; Value: Smallint);
  817. begin
  818.   ControlInterface.ClearStandardIRList[index] := Value;
  819. end;
  820.  
  821. procedure TVSSpell.Set_CloseDictionary(index: Smallint; Value: Smallint);
  822. begin
  823.   ControlInterface.CloseDictionary[index] := Value;
  824. end;
  825.  
  826. procedure TVSSpell.Set_GetEntry(index: Smallint; Value: Integer);
  827. begin
  828.   ControlInterface.GetEntry[index] := Value;
  829. end;
  830.  
  831. procedure TVSSpell.Set_RemoveFromStandardIRList(index: Smallint; const Value: WideString);
  832. begin
  833.   ControlInterface.RemoveFromStandardIRList[index] := Value;
  834. end;
  835.  
  836. function TVSSpell.Get_DictionaryPerformanceActual(index: Smallint): Smallint;
  837. begin
  838.   Result := ControlInterface.DictionaryPerformanceActual[index];
  839. end;
  840.  
  841. function TVSSpell.Get_DictionaryBlockCount(index: Smallint): Smallint;
  842. begin
  843.   Result := ControlInterface.DictionaryBlockCount[index];
  844. end;
  845.  
  846. function TVSSpell.Get_DictionaryBlockSize(index: Smallint): Smallint;
  847. begin
  848.   Result := ControlInterface.DictionaryBlockSize[index];
  849. end;
  850.  
  851. function TVSSpell.Get_DictionaryCommonCount(index: Smallint): Smallint;
  852. begin
  853.   Result := ControlInterface.DictionaryCommonCount[index];
  854. end;
  855.  
  856. function TVSSpell.Get_DictionaryCompatibilityBits(index: Smallint): Smallint;
  857. begin
  858.   Result := ControlInterface.DictionaryCompatibilityBits[index];
  859. end;
  860.  
  861. function TVSSpell.Get_DictionaryCopyright(index: Smallint): WideString;
  862. begin
  863.   Result := ControlInterface.DictionaryCopyright[index];
  864. end;
  865.  
  866. function TVSSpell.Get_DictionaryCopyrightDerived(index: Smallint): WideString;
  867. begin
  868.   Result := ControlInterface.DictionaryCopyrightDerived[index];
  869. end;
  870.  
  871. function TVSSpell.Get_DictionaryFlags(index: Smallint): Smallint;
  872. begin
  873.   Result := ControlInterface.DictionaryFlags[index];
  874. end;
  875.  
  876. function TVSSpell.Get_DictionaryLoadCount(index: Smallint): Smallint;
  877. begin
  878.   Result := ControlInterface.DictionaryLoadCount[index];
  879. end;
  880.  
  881. function TVSSpell.Get_DictionaryMakerVersion(index: Smallint): Smallint;
  882. begin
  883.   Result := ControlInterface.DictionaryMakerVersion[index];
  884. end;
  885.  
  886. function TVSSpell.Get_DictionaryOpenCount(index: Smallint): Smallint;
  887. begin
  888.   Result := ControlInterface.DictionaryOpenCount[index];
  889. end;
  890.  
  891. function TVSSpell.Get_DictionarySymbolSetSize(index: Smallint): Smallint;
  892. begin
  893.   Result := ControlInterface.DictionarySymbolSetSize[index];
  894. end;
  895.  
  896. function TVSSpell.Get_DictionaryWordCount(index: Smallint): Integer;
  897. begin
  898.   Result := ControlInterface.DictionaryWordCount[index];
  899. end;
  900.  
  901. procedure TVSSpell.Set_CreateCustomExtended(index: Smallint; const Value: WideString);
  902. begin
  903.   ControlInterface.CreateCustomExtended[index] := Value;
  904. end;
  905.  
  906. procedure TVSSpell.Set_EnableDictionary(index: Smallint; Value: WordBool);
  907. begin
  908.   ControlInterface.EnableDictionary[index] := Value;
  909. end;
  910.  
  911. procedure TVSSpell.Set_EnableCustomUpdate(index: Smallint; Value: WordBool);
  912. begin
  913.   ControlInterface.EnableCustomUpdate[index] := Value;
  914. end;
  915.  
  916. procedure TVSSpell.Set_LoadDictionary(index: Smallint; Value: Smallint);
  917. begin
  918.   ControlInterface.LoadDictionary[index] := Value;
  919. end;
  920.  
  921. procedure TVSSpell.Set_UnloadDictionary(index: Smallint; Value: Smallint);
  922. begin
  923.   ControlInterface.UnloadDictionary[index] := Value;
  924. end;
  925.  
  926. function TVSSpell.Get_CustomIsReadOnly(index: Smallint): WordBool;
  927. begin
  928.   Result := ControlInterface.CustomIsReadOnly[index];
  929. end;
  930.  
  931. function TVSSpell.Get_CustomIsExtended(index: Smallint): WordBool;
  932. begin
  933.   Result := ControlInterface.CustomIsExtended[index];
  934. end;
  935.  
  936. procedure TVSSpell.Set_EnableStandardIRList(index: Smallint; Value: WordBool);
  937. begin
  938.   ControlInterface.EnableStandardIRList[index] := Value;
  939. end;
  940.  
  941. procedure TVSSpell.Set_OpenCustom(loadit: WordBool; const Value: WideString);
  942. begin
  943.   ControlInterface.OpenCustom[loadit] := Value;
  944. end;
  945.  
  946.  
  947. procedure Register;
  948. begin
  949.   RegisterComponents('ActiveX', [TVSSpell]);
  950.   RegisterNonActiveX([TVSSpell]);
  951. end;
  952.  
  953. end.
  954.